<?php


namespace App\Http\Controllers;

use App\Models\Category;
use App\Models\Filter;

class GuanyuController extends Controller
{
    public function guanyu()
    {
        $catelist = Category::getCateListBy('guanyu');
        //Filter::resourceLink('https://www.szweb.cn/guanyu');
        Filter::cutStr(
            'https://www.szweb.cn/guanyu',
            '<div class="about-us-intro weblg">',
            '<div class="full-related-news">',
            'guanyu/guanyu'
        );
        $cate = Category::getCateByTargetName("guanyu");
        return view("guanyu.guanyu",compact("cate", "catelist"));
    }


    public function shili()
    {
        $catelist = Category::getCateListBy('guanyu');
       //Filter::resourceLink('https://www.szweb.cn/shili/');
        Filter::cutStr(
            'https://www.szweb.cn/shili/',
            '<div class="history-wapper">',
            '<div class="full-related-news">',
            'guanyu/shili'
        );
        $cate = Category::getCateByTargetName("shili");
        return view("guanyu.shili",compact("cate", "catelist"));
    }


    public function yuzhongbutong()
    {
        $catelist = Category::getCateListBy('guanyu');
       //Filter::resourceLink('https://www.szweb.cn/yuzhongbutong');
        Filter::cutStr(
            'https://www.szweb.cn/yuzhongbutong',
            '<div class="diff-head weblg">',
            '<div class="full-related-news">',
            'guanyu/yuzhongbutong'
        );
        $cate = Category::getCateByTargetName("yuzhongbutong");
        return view("guanyu.yuzhongbutong",compact("cate", "catelist"));
    }


    public function linian()
    {
        $catelist = Category::getCateListBy('guanyu');
       //Filter::resourceLink('https://www.szweb.cn/linian');
        Filter::cutStr(
            'https://www.szweb.cn/linian',
            '<div class="full-faith-article">',
            '<div class="full-related-news">',
            'guanyu/linian'
        );
        $cate = Category::getCateByTargetName("linian");
        return view("guanyu.linian",compact("cate", "catelist"));
    }


    public function shouhou()
    {
        $catelist = Category::getCateListBy('guanyu');
       //Filter::resourceLink('https://www.szweb.cn/shouhou');
        Filter::cutStr(
            'https://www.szweb.cn/shouhou',
            '<div class="doc-download weblg">',
            '<div class="full-related-news">',
            'guanyu/shouhou'
        );
        $cate = Category::getCateByTargetName("shouhou");
        return view("guanyu.shouhou",compact("cate", "catelist"));
    }


    public function kehu()
    {
        $catelist = Category::getCateListBy('guanyu');
       //Filter::resourceLink('https://www.szweb.cn/kehu');
        Filter::cutStr(
            'https://www.szweb.cn/kehu',
            '<div class="customer-article weblg">',
            '<div class="full-related-news">',
            'guanyu/kehu'
        );
        $cate = Category::getCateByTargetName("kehu");
        return view("guanyu.kehu",compact("cate", "catelist"));
    }


    public function comments()
    {
        $catelist = Category::getCateListBy('guanyu');
       //Filter::resourceLink('https://www.szweb.cn/comments');
        Filter::cutStr(
            'https://www.szweb.cn/comments',
            '<div class="weblg evaluate-wrapper">',
            '<div class="full-related-news">',
            'guanyu/comments'
        );
        $cate = Category::getCateByTargetName("comments");
        return view("guanyu.comments",compact("cate", "catelist"));
    }
}